package view;

import java.awt.Point;
import java.util.List;

import controller.Movement;

/**
 * Interface for controlling the game display
 */
public interface ViewController {
	
	/**
	 * Gets user's chosen movement from the game display 
	 * @return movement chosen by user through the display
	 */
	public Movement getMovement();
	
	/**
	 * Displays the game board
	 */
	public void displayBoard();
	
	/**
	 * Adds panels in order to add pieces according to user's choice
	 */
	public void setPiecesFromUser();
	
	/**
	 * Notifies user that game has reached Check
	 */
	public void notifyCheck();
	
	/**
	 * Notifies user that game is over and displays given message
	 * @param msg- message to display
	 */
	public void notifyGameOver(String msg);
	
	/**
	 * Asks user for piece to replace Pawn
	 * @param options- options for replacing pieces
	 * @param defaultOption- default option for replacing piece
	 * @return user's choice for replacing piece
	 */
	public int replacePawn(String[] options, int defaultOption);
	
	/**
	 * Initializes the display 
	 */
	public void initializeDisplay();
	
	/**
	 * Refreshes Creatures' positions and positions where two Creatures were collided 
	 */
	public void refreshDisplayBeforeMove(List<Point> creaturePositions, List<Point> collidingCreatures);
	
	/**
	 * Refreshes the board display according to move made, Creature positions, colliding Creatures and Creature that killed a piece
	 * @param movement- movement on current turn
	 * @param killerCreature- position of Creature that has killed a piece on current turn
	 */
	public void refreshDisplayAfterMove(Movement movement, Point killerCreature);
	
	/**
	 * Cleans the collided and killed Creatures from the game display
	 * @param collidedCreatures- Creatures that collided on current turn
	 * @param killedCreatures- Creatures that were killed on current turn
	 */
	public void cleanKilledCreatures(List<Point> collidedCreatures, List<Point> killedCreatures);
}
